<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>账号设置 - Powered By Betou</title>
<meta name="author" content="Betou Team" />
<meta name="copyright" content="Betou" />
<#include "../head.html"/>
<script type="text/javascript">
$().ready(function() {
	
	var $inputForm = $("#inputForm");
	
	// 表单验证
	$inputForm.validate({
		rules: {
			password: {
				pattern: /^[^\s&\"<>]+$/,
				minlength: 4,
				maxlength: 20
			},
			rePassword: {
				equalTo: "#password"
			},
			mobile: { digits:true, minlength:11, remote:{
				url:"../v_check_mobile.jspx",
				cache:false,
				oldValue:"${bean.mobile!}"
			} },
			email: {email:true, maxlength:100,remote:{
				url:"../v_check_email.jspx",
				oldValue:"${bean.email!}"
			}},
			qqService:{digits:true, minlength:5}
		},
		messages: {
			password: {
				pattern: "非法字符"
			},
			email:{
				remote:"已存在"
			},
			mobole:{remote:"已存在"}
		
		}
		
	});
	
});
</script>
</head>
<body class="content">
	<div class="path">
		<a href="../index.jspx">首页</a> &raquo; 账号设置&raquo; ${bean.username!}
	</div>
	<form id="inputForm" action="o_update_agentadmin.jspx" method="post"  >
		<input type="hidden" name="id" value="${bean.id!}" />
		<#list bean.roles as p>
			<input type="hidden" name="roleIds" value="${p.id!}"/>
		</#list>
		<input type="hidden" name="disabled" value="${bean.disabled?string('true', 'false')}"/>
		<table class="input tabContent">
			<tr>
				<th>登录名:</th>
				<td>
					${bean.username!}
				</td>
			</tr>
			<tr>
				<th>密码:</th>
				<td>
					<input name="password"  type="password" id="password" class="text" maxlength="100" />
				</td>
			</tr>
			<tr>
				<th>确认密码:</th>
				<td>
					<input type="password" name="rePassword"  class="text" maxlength="100"  />
				</td>
			</tr>
			<tr>
				<th>Email:</th>
				<td>
					<input type="text" name="email" class="text" maxlength="100" value="${bean.email!}"/>
				</td>
			</tr>
			<tr>
				<th>手机号码:</th>
				<td>
					<input type="text" name="mobile" class="text" maxlength="11" value="${bean.mobile!}"/>
				</td>
			</tr>
			<tr>
				<th>真实姓名:</th>
				<td>
						<input type="text" name="realname" class="text" maxlength="30"  value="${bean.ext.realname!}" />
				</td>
			</tr>
			<tr>
				<th>部门:</th>
				<td>
						<input type="text" name="contract" class="text" maxlength="30"  value="${bean.ext.contract!}"/>
				</td>
			</tr>
			<tr>
				<th>性别:</th>
				<td>
						<select name="gender">
							<option value="1" <#if bean.ext.gender>selected</#if> >男</option>
							<option value="0" <#if !bean.ext.gender>selected</#if>>女</option>
						</select>
				</td>
			</tr>
			<tr>
				<th>联系地址:</th>
				<td>
						<input type="text" name="address" class="text" maxlength="100"  value="${bean.ext.address!}" />
				</td>
			</tr>
			<tr>
				<th>联系电话:</th>
				<td>
						<input type="text" name="tel" class="text" maxlength="100"  value="${bean.ext.tel!}" />
				</td>
			</tr>
			<tr>
				<th>常用QQ:</th>
				<td>
						<input type="text" name="qqService" class="text" maxlength="15"  value="${bean.ext.qqService!}"/>
				</td>
			</tr>
		</table>
		
		<table class="input">
			<tr>
				<th>
					&nbsp;
				</th>
				<td>
					<input type="submit" class="button" value="确&nbsp;&nbsp;定" />
				</td>
			</tr>
		</table>
	</form>
</body>
</html>
